import request from '@/utils/request'

// 获取水厂下拉列表
export function getFactoryList() {
  return request({
    url: '/operation/web/operationWaterworksKPI/factoryList',
    method: 'get'
  })
}

// 获取设备运行状态
export function getEquipmentStatus() {
  return request({
    url: '/operation/web/operationWaterworksKPI/status',
    method: 'get'
  })
}

// 获取水质统计
export function getWaterQualityStatistics(params) {
  return request({
    url: '/operation/web/operationWaterworksKPI/waterQualityStatistics',
    method: 'get',
    params
  })
}

// 获取设备故障率趋势
export function getFailureRateTrend() {
  return request({
    url: '/operation/web/operationWaterworksKPI/dynamicFailureRateTrend',
    method: 'get'
  })
}

// 获取供水统计
export function getSupplyStatistics(params) {
  return request({
    url: '/operation/web/operationWaterworksKPI/supplyStatistics',
    method: 'get',
    params
  })
}

// 获取工单处理效率
export function getWorkOrderEfficiency() {
  return request({
    url: '/operation/web/operationWaterworksKPI/efficiency',
    method: 'get'
  })
}

// 获取成本统计
export function getCostStatistics(params) {
  return request({
    url: '/operation/web/operationWaterworksKPI/costStatistics',
    method: 'get',
    params
  })
}

// 获取工单完成率
export function getWorkOrderCompletionRate() {
  return request({
    url: '/operation/web/operationWaterworksKPI/completionRate',
    method: 'get'
  })
}

// 获取待办任务
export function getTodoTasks(params) {
  return request({
    url: '/operation/web/operationWaterworksKPI/todoTask',
    method: 'get',
    params
  })
}

// 获取水质指标图表数据
export function getWaterQualityIndex(params) {
  return request({
    url: '/operation/web/operationWaterworksKPI/waterQualityIndex',
    method: 'get',
    params
  })
}

// 获取水质达标率
export function getWaterQualityStandardRate(params) {
  return request({
    url: '/operation/web/operationWaterworksKPI/waterQualityStandardRate',
    method: 'get',
    params
  })
}

// 获取日供水量趋势
export function getTargetTrend() {
  return request({
    url: '/operation/web/operationWaterworksKPI/targetTrend',
    method: 'get'
  })
}

// 获取产能利用率
export function getCapacityUtilization() {
  return request({
    url: '/operation/web/operationWaterworksKPI/capacityUtilization',
    method: 'get'
  })
}

// 获取成本构成分析
export function getCostComposition() {
  return request({
    url: '/operation/web/operationWaterworksKPI/composition',
    method: 'get'
  })
}

// 获取单位成本对比
export function getUnitCostComparison() {
  return request({
    url: '/operation/web/operationWaterworksKPI/unitCostComparison',
    method: 'get'
  })
}